The ksleep( ) system call provides the capability that user space locks can be released after placing a thread in a kernel sleep queue. Synchronization of releasing the user space locks is needed in order for user space libraries to avoid missing wakeup signals. Because the lock is held in user space, a copyout( ) system call is used to release the lock from kernel space.